<template>
  <div>
    <el-button @click="handleClickRefresh"> 刷新 </el-button>
    <el-button type="primary"> 申请证书 </el-button>
    <el-button> More </el-button>
  </div>
</template>
  
  <script>
export default {
  name: "domains-toolbar",

  computed: {
    DomainName() {
      return this.$route.params["domain"];
    },
  },

  methods: {
    fetch() {
      let dn = this.DomainName;
      this.$store.dispatch("certificates/fetchWithDomainName", { dn });
    },

    handleClickRefresh() {
      this.fetch();
    },
  },

  mounted() {
    this.fetch();
  },
};
</script>
  